# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=py3-pytest-asyncio
pkgver=0.18.3
pkgrel=0
pkgdesc="Pytest support for asyncio"
url="https://github.com/pytest-dev/pytest-asyncio"
arch="noarch"
license="Apache-2.0"
depends="python3 py3-flaky py3-pytest py3-pytest-trio"
makedepends="py3-setuptools py3-setuptools_scm"
checkdepends="py3-async_generator py3-coverage py3-hypothesis"
options="!check" # doesn't find its own modules
source="$pkgname-$pkgver.tar.gz::https://github.com/pytest-dev/pytest-asyncio/archive/v$pkgver.tar.gz"
builddir="$srcdir/pytest-asyncio-$pkgver"

build() {
	export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
	python3 setup.py build
}

check() {
	PYTHONPATH="$PWD/build/lib" py.test-3
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="
04d2046c039131598cb593afc1908be0dff2b24a91c89f36fca75d2d65916571e48fe149c1ba90244f299586277320cf6f130a02824fde9ee0a4d2429bf58a54  py3-pytest-asyncio-0.18.3.tar.gz
"
